package org.tea.inventory.enums;

import lombok.Getter;
import lombok.Setter;

/**
 * @author hanzy
 * @description 证书类型
 * @date 2023年04月06日 14:03
 */
public enum MallCertificateTypeEnum {
    IT_I("10", "IT类重要", 2000L),
    IT_II("11", "IT类一般", 500L),
    NO_IT("20", "非IT类", 500L),

    ;

    @Getter
    @Setter
    private String code;
    @Getter
    @Setter
    private String content;

    @Getter
    @Setter
    private Long num;

    MallCertificateTypeEnum(String code, String content, Long num) {
        this.code = code;
        this.content = content;
        this.num = num;
    }

    public static String getContentByName(String code) {
        for (MallCertificateTypeEnum productAttributeEnum : MallCertificateTypeEnum.values()) {
            if (productAttributeEnum.getCode().equals(code)) {
                return productAttributeEnum.getContent();
            }
        }
        return "";
    }


}
